const mongoose = require('mongoose');

const ProductSchema = new mongoose.Schema({
  productMetadata: {
    masterId: {type: String, required: true},
    version: {type: Number, required: true, default: 0}
  },
  sku: {type: String, required: true},
  itemType: {type: String, required: true},
}, {collection: 'Products', timestamps: true});

mongoose.model('ProductSchema', ProductSchema);